package com.wrx.club_management_backend.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.wrx.club_management_backend.entity.AllocationRequest;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;

@Mapper
public interface AllocationRequestMapper extends BaseMapper<AllocationRequest> {

    @Update("update tb_allocation_request set stat = #{stat} where id = #{requestId}")
    void updateStatus(@Param("requestId") Long requestId, @Param("stat") int stat);

    @Update("update tb_allocation_request set allocation_notice_id = #{noticeId} where id = #{requestId}")
    void  updateNoticeId(@Param("noticeId") Long noticeId, @Param("requestId") Long requestId);
}
